<!DOCTYPE html>

{% extends 'base.html' %}
{% load staticfiles %}

{% block title %}慕学在线网首页{% endblock %}

{% block header %}
<nav>
				<div class="nav">
					<div class="wp">
						<ul>
							<li class="active"><a href="{% url 'index' %}">首页</a></li>
							<li >
								<a href="{% url 'course:course_list' %}">
									公开课<img class="hot" src="/static/images/nav_hot.png">
								</a>
							</li>
							<li >
								<a href="{% url 'org:teacher_list' %}">授课教师</a>
							</li>
							<li ><a href="{% url 'org:org_list' %}">授课机构</a></li>
						</ul>
					</div>
				</div>
			</nav>
{% endblock %}

{% block content %}
<div class="banner">
        <div class="wp">
            <div class="fl">
                <div class="imgslide">
                    <ul class="imgs">
                            {% for banner in all_banners %}
                            <li>
                                <a href="{{ banner.url }}">
                                    <img width="1200" height="478" class="scrollLoading"  src="{{ MEDIA_URL }}{{ banner.image }}" />
                                </a>
                            </li>
                            {% endfor %}

                    </ul>
                </div>
                <div class="unslider-arrow prev"></div>
                <div class="unslider-arrow next"></div>
            </div>
<!--<<<<<<< HEAD-->
            <div class="fr">
                <div class="top">
                    <ul class="sec_topr_tab">
                        <li class="sec_top_li on" data-type="1"><a href="javascript:;">课程咨询</a></li>
                    </ul>
                    <i class="index_ico_arrow"></i>
                    <p class="sec_top_p" id="secTips">留下联系方式，快速获取信息</p>
                    <form id="jsDemandForm">
                        <input type="hidden" id="jsWantType" name="want_type" value="1">
                        <input class="icon1" id="name" name="name" type="text" placeholder="请输入姓名"/>
                        <input class="icon2" id="mobile" name="mobile" type="text" placeholder="请输入手机号码"/>
                        <input class="icon2" id="mobile" name="mobile" type="text" placeholder="请输入课程"/>
                        <p class="demand_form_tips" id="jsDemandTips"></p>
                        <input class="submit demand_form_btn" id="jsDemandBtn" type="button" value="点击提交" />
                        <input type='hidden' name='csrfmiddlewaretoken' value='mymQDzHWl2REXIfPMg2mJaLqDfaS1sD5' />
                    </form>
                </div>
                <div class="bottom">
                    <h1>最新课程<a class="more" href="article-list.html">更多></a> </h1>
                    <ul>
                            <li><a href="/knowledge/detail/3/">django中如何实现多数据库配置</a></li>
                            <li><a href="/knowledge/detail/2/">python逐渐成为高校首选课程</a></li>
                    </ul>
                </div>
            </div>
            <!--<div class="fr">-->
                <!--<div class="top">-->
                    <!--<ul class="sec_topr_tab">-->
                        <!--<li class="sec_top_li on" data-type="1"><a href="javascript:;">课程咨询</a></li>-->
                        <!--<li class="sec_top_li" data-type="2"><a href="javascript:;">教师咨询</a></li>-->
                    <!--</ul>-->
                    <!--<i class="index_ico_arrow"></i>-->
                    <!--<p class="sec_top_p" id="secTips">留下联系方式，快速获取信息</p>-->
                    <!--<form id="jsDemandForm">-->
                        <!--<input type="hidden" id="jsWantType" name="want_type" value="1">-->
                        <!--<input class="icon1" id="name" name="name" type="text" placeholder="请输入姓名"/>-->
                        <!--<input class="icon2" id="mobile" name="mobile" type="text" placeholder="请输入手机号码"/>-->
                        <!--<input class="icon2" id="mobile" name="mobile" type="text" placeholder="请输入课程"/>-->
                        <!--<p class="demand_form_tips" id="jsDemandTips"></p>-->
                        <!--<input class="submit demand_form_btn" id="jsDemandBtn" type="button" value="点击提交" />-->
                        <!--<input type='hidden' name='csrfmiddlewaretoken' value='mymQDzHWl2REXIfPMg2mJaLqDfaS1sD5' />-->
                    <!--</form>-->
                <!--</div>-->
                <!--<div class="bottom">-->
                    <!--<h1>最新文章<a class="more" href="article-list.html">更多></a> </h1>-->
                    <!--<ul>-->
                            <!--<li><a href="/knowledge/detail/3/">django中如何实现多数据库配置</a></li>-->
                            <!--<li><a href="/knowledge/detail/2/">python逐渐成为高校首选课程</a></li>-->
                    <!--</ul>-->
                <!--</div>-->
            <!--</div>-->

        </div>
    </div>
<section>
    <div class="wp">
        <ul class="feature">
            <li class="feature1">
                <img class="pic" src="/static/images/feature1.png"/>
                <p class="center">专业权威</p>
            </li>
            <li class="feature2">
                <img class="pic" src="/static/images/feature2.png"/>
                <p class="center">课程最新</p>
            </li>
            <li class="feature3">
                <img class="pic" src="/static/images/feature3.png"/>
                <p class="center">名师授课</p>
            </li>
            <li class="feature4">
                <img class="pic" src="/static/images/feature4.png"/>
                <p class="center">数据真实</p>
            </li>
        </ul>
    </div>
</section>
<section>
    <div class="module">
        <div class="wp">
            <h1>公开课程</h1>
            <div class="module1 eachmod">
                <div class="module1_1 left">
                    <img width="228" height="614" src="/static/images/module1_1.jpg"/>
                    <p class="fisrt_word">名师授课<br/>专业权威</p>
                    <a class="more" href="{% url 'course:course_list' %}">查看更多课程 ></a>
                </div>
                <div class="right group_list">
                    <div class="module1_2 box">
                        <div class="imgslide2">
                            <ul class="imgs">
                                    {% for banner_course in banner_courses %}
                                    <li>
                                        <a href="{% url 'course:course_detail' banner_course.id %}">
                                            <img width="470" height="300" class="scrollLoading"  src="{{ MEDIA_URL }}{{ banner_course.image }}" />
                                        </a>
                                    </li>
                                    {%  endfor %}

                            </ul>
                        </div>
                        <div class="unslider-arrow2 prev"></div>
                        <div class="unslider-arrow2 next"></div>
                    </div>
                        {% for course in courses %}
                        <div class="module1_{{ forloop.counter|add:2 }} box">
                            <a href="{% url 'course:course_detail' course.id %}">
                                <img width="233" height="190" class="scrollLoading"  src="{{ MEDIA_URL }}{{ course.image }}"/>
                            </a>
                            <div class="des">
                                <a href="{% url 'course:course_detail' course.id %}">
                                    <h2 title="{{ course.name }}">{{ course.name }}</h2>
                                </a>
                                <span class="fl">难度：<i class="key">{{ course.get_degree_display }}</i></span>
                                <span class="fr">学习人数：{{ course.students }}</span>
                            </div>
                            <div class="bottom">
                                <span class="fl" title="{{ course.course_org.name }}">{{ course.course_org.name }}</span>
                                <span class="star fr">{{ course.fav_nums }}</span>
                            </div>
                        </div>
                        {% endfor %}

                </div>
            </div>
        </div>
    </div>
</section>
<section>
    <div class="module greybg">
        <div class="wp">
            <h1>培训机构</h1>
            <div class="module3 eachmod">
                <div class="module3_1 left">
                    <img width="228" height="463" src="/static/images/module3_1.jpg"/>
                    <p class="fisrt_word">名校来袭<br/>权威认证</p>
                    <a class="more" href="org-list.html">查看更多机构 ></a>
                </div>
                <div class="right">
                    <ul>
                        {% for org in course_orgs %}
                            <li class="{% if forloop.counter|divisibleby:5 %}five{% endif %}">
                                <a href="{% url 'org:org_home' org.id %}">
                                    <div class="company">
                                        <img width="184" height="100" class="scrollLoading"  src="{{ MEDIA_URL }}{{ org.image }}"/>
                                        <div class="score">
                                            <div class="circle">
                                                <h2>{{ org.tag }}</h2>
                                                <p>评分</p>
                                            </div>
                                        </div>
                                    </div>
                                    <p><span class="key" title="{{ org.name }}">{{ org.name }}</span></p>
                                </a>
                            </li>
                        {% endfor %}
                    </ul>
                </div>
            </div>
        </div>
    </div>
</section>
{% endblock %}

{% block custom_js %}
<script type="text/javascript" src="/static/js/index.js"></script>
{% endblock %}


